package com.xbongbong.paas.pojo.dto;

import com.xbongbong.paas.domain.entity.ext.ConditionsEntityExt;
import com.xbongbong.paas.toolbox.wrap.BaseDTO;
import com.xbongbong.paas.toolbox.wrap.QueryIgnore;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.List;

/**
 * @author: wufeng
 * @date: 2018/9/7 16:17
 * @desrcption:
 */
@Getter
@Setter
@ToString
public class ListGroupAddDTO extends BaseDTO {

    private static final long serialVersionUID = -4425883486466216171L;

    /**
     * 应用id
     */
    @NotNull(message = "{dto.msg.listGroupAdd.appId.NotNull}")
    private Long appId;

    /**
     * 表单id
     */
    @NotNull(message = "{dto.msg.listGroupAdd.formId.NotNull}")
    private Long formId;
    /**
     * 列表分组名称
     */
    @NotBlank(message = "{dto.msg.listGroupAdd.name.NotBlank}")
    @Getter(onMethod_ = {@QueryIgnore})
    @Size(max = 10,message = "{dto.msg.listGroupAdd.name.Size}")
    private String name;

    @NotEmpty(message = "{dto.msg.listGroupAdd.data.NotEmpty}")
    @Getter(onMethod_ = {@QueryIgnore})
    private List<ConditionsEntityExt> data;

    /**
     * saas标记
     */
    @Getter(onMethod_ = {@QueryIgnore})
    private Integer saasMark;

    /**
     * 业务类型
     */
    @Getter(onMethod_ = {@QueryIgnore})
    private Integer businessType;
}
